#ifndef IMAGERECOVER_H
#define IMAGERECOVER_H


#include "imageshared.h"
#include "myecpoint.h"
#include "qjsonobject.h"
class imageRecover
{
public:
    imageRecover(std::shared_ptr<EC_GROUP> group);
    QJsonObject getJsonObject() const{return m_obj;}
    bool setPubInfo(QString pubInfoFileName,void(*logFun)(QString)=nullptr);
    QByteArrayList getFrx(int setNum, QString imageFileName, SaveMethod method);
private:
    QJsonObject m_obj;
    std::shared_ptr<EC_GROUP> m_group=nullptr;//椭圆曲线
    MyECPoint m_point;  //椭圆曲线基点
    QByteArrayList splitImage(uchar *data, int w, int n);
    int m_N = 0;//秘密图像分组数
    int m_k = 0;//每组秘密的每个子秘密的像素个数
    int m_dep=0;//位深
};

#endif // IMAGERECOVER_H
